<?php

/**
 * ExtViewportBase class file
 *
 * @author TrueSoftware B.V. (The Netherlands)
 * @link http://www.ext4yii.com
 * @copyright Copyright 2007-2010 TrueSoftwareB.V. all rights reserved.
 * @license http://www.ext4yii.com/license/
 *          EVALUATION VERSION - NOT FOR COMMERCIAL USE OR DISTRIBUTION.
 * @version 0.7.2
 */
class ExtViewportBase extends ExtContainer
{

    public function parseNode(ExtHTMLParserNode $node, ExtASTWalker $astwalker)
    {
        parent::parseNode($node, $astwalker);
        $body = $node->findPropertyByName('body');
        if (!is_null($body))
        {
            $items = parent::parseNodeWidthTag($body,
                            $astwalker,
                            true,
                            array('asobject' => false),
                            $this);
            if(count($items) != 0)
                $this->setArrayConfig('items', $items);
            $body->shiftUp();
        }
    }

    public function createContainer(ExtHTMLParserNode $node)
    {
        $this->setJavaScriptConfig('renderTo', 'Ext.getBody()');
        $node->shiftUp();
    }

}

?>
